package cn.androidlongs.study.user.service;

import cn.androidlongs.study.user.dao.UserDao;
import cn.androidlongs.study.user.vo.UserModel;

public class UserService {

    private UserDao userDao ;
    public void setUserDao(UserDao userDao) {
	this.userDao = userDao;
    }
    public UserDao getUserDao() {
	return userDao;
    }
    
    public UserModel loginFunction(String name, String password) {
	if (name==null||name.equals("")||password==null||password.equals("")) {
	    return null;
	}
	return userDao.queryUserFromNameAndPas(name,password);
    }

}
